package com.guocheng.modules.login.model.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 用户实体类
 */
@Data
@Accessors(chain = true)
@TableName("sys_user")
public class User implements Serializable {
    //id
    @TableId(type = IdType.AUTO)
    private Integer id;
    //用户名
    private String username;
    //性别
    private String sex;
    //密码
    @JsonIgnore
    private String password;
    //所属部门名称
    private String deptName;
    //所属部门id
    private Integer deptId;
    //邮箱
    private String email;
    //手机号
    private String mobile;
    //状态
    private Integer status;
    //创建时间
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createDate;
}
